<!--{template common/header_ajax}-->
<!-- Begin pic box -->
<div class="box_pic" style="height:{$pic_height}px; line-height:{$pic_height}px;">
        <div class="behivator" style="height:{$pic_height}px;">
            <a href="home.php?mod=space&uid=$pic[uid]&do=$do&picid=$upid&goto=up"  id="prev_pic"  onclick="show_pic(this.href, $_GET[feedid]);return false;" class="btn" title="{lang previous_pic}"><div style="text-align:left; width:398px; float:left; height:{$pic_height}px; line-height:{$pic_height}px; vertical-align:middle;" onmouseover="pic_onmouseover('move_pre');" onmouseout="pic_onmouseout('move_pre');"><img src="{STATICURL}image/common/pic-prev.png" id="move_pre" style="display:none" alt="{lang previous_pic}"/>&nbsp;</div></a>
            <a href="home.php?mod=space&uid=$pic[uid]&do=$do&picid=$nextid&goto=down" id="next_pic" onclick="show_pic(this.href, $_GET[feedid]);return false;" class="btn" title="{lang next_pic}"><div style="text-align:right; width:398px;float:right; height:{$pic_height}px; line-height:{$pic_height}px; vertical-align:middle;" onmouseover="pic_onmouseover('move_next');" onmouseout="pic_onmouseout('move_next');">&nbsp;<img src="{STATICURL}image/common/pic-next.png" style="display:none" id="move_next" alt="{lang next_pic}"/></div></a>
        </div>
                         <!--{if $pic[magicframe]}-->
                        <div class="pic_lb1">
                           <table cellpadding="0" cellspacing="0" class="">
                                <tr>
                                    <td class="frame_jiao frame_top_left"></td>
                                    <td class="frame_x frame_top_middle"></td>
                                    <td class="frame_jiao frame_top_right"></td>
                                </tr>
                                <tr>
                                    <td class="frame_y frame_middle_left"></td>
                                    <td class="frame_middle_middle">
                        <!--{/if}-->	
                                        <img style="max-width:800px;" src="$pic[pic]" align="middle" id="pic" alt="" />
                        <!--{if $pic[magicframe]}-->
                                    </td>
                                    <td class="frame_y frame_middle_right"></td>
                                </tr>
                                <tr>
                                    <td class="frame_jiao frame_bottom_left"></td>
                                    <td class="frame_x frame_bottom_middle"></td>
                                    <td class="frame_jiao frame_bottom_right"></td>
                                </tr>
                            </table>
                        </div>
                        <!--{/if}-->
    <div style="clear:both"></div>
</div>
<!-- /End display pic -->

<div class="y" style="padding:10px;">
    <!--
    <a href="javascript:;" onclick="imageRotate('pic', 1)"><img class="vm" src="{STATICURL}image/common/rleft.gif" /></a>
    <span class="pipe">|</span>
    <a href="javascript:;" onclick="imageRotate('pic', 2)"><img class="vm" src="{STATICURL}image/common/rright.gif" /></a>
    <span class="pipe">|</span>
    -->
    <a href="home.php?mod=spacecp&ac=share&type=pic&id=$pic[picid]&handlekey=sharealbumhk_{$pic[picid]}" id="a_share_$pic[picid]" onclick="showWindow(this.id, this.href, 'get', 0);" class="oshr">{lang share}</a>
    
    
</div>
<div class="clearfix">
    <!-- Author and comment pic colum -->
    <div id="pic_author_$pic[pic]" style="padding:10px 0; width:520px; float:left;">
    <!-- Pic author information -->
        <table cellpadding="0" cellspacing="0">
            <tbody>
                <tr>
                    <td class="avt" width="50px" valign="top">
                    <!--{avatar($space[uid],small)}-->
                    </td>
                    <td valign="top" align="left" width="*">
                        <div style="padding-left:5px; line-height:20px;">
                            <div><a href="home.php?mod=space&username=$space[username]"><strong>$space[username]</strong></a></div>
                            <div>
                                <p id="a_set_title">
                                    <!--{if $pic[title]}-->$pic[title]<!--{else}--><!--{eval echo substr($pic['filename'], 0, strrpos($pic['filename'], '.'));}--><!--{/if}--><!--{if $pic[status] == 1}--><b>({lang moderate_need})</b><!--{/if}-->
                                </p>
                            </div>
                        </div>
                    </td>
                </tr>
            </tbody>
        </table>
        <div style="line-height:24px;padding-top:20px; text-align:left;">
    	<!--{if $pic['location']}-->
        	Chụp tại: $pic['location']
        <!--{/if}-->
        <!--{if !empty($pic['tagfriends'])}-->
        	cùng với:
            <!--{eval $tgi = 0; $tgc = count($pic['tagfriends']);}-->
            <!--{loop $pic['tagfriends'] $key $value}-->
            	<!--{eval $tgi++}-->
            	<a href="home.php?mod=space&username={$value[username]}" c="1">{$value[username]}</a><!--{if $tgi<$tgc-1}-->,<!--{/if}--><!--{if $tgi == $tgc-1}--> và <!--{/if}-->
            <!--{if $value[username] == $_G['username']}-->
            <!--{eval $removetag = true;}-->
            <!--{/if}-->
            <!--{/loop}-->.
            <!--{if $removetag}-->
            <a href="home.php?mod=spacecp&ac=album&op=removetag&picid={$pic[picid]}" onclick="showWindow('removetag', this.href); return false;">Huỷ tag tôi</a>
            <!--{/if}-->
        <!--{/if}-->
    	</div>
        <div class="xg1 xs1" style="padding-top:20px; text-align:left;">
            <!--{if $pic[hot]}--><span class="hot">{lang hot} <em>$pic[hot]</em></span> - <!--{/if}-->
            <!--{if $do=='event'}--><a href="home.php?mod=space&uid=$pic[uid]">$pic[username]</a> - <!--{/if}-->
            {lang upload_at} <!--{date($pic[dateline])}--> ($pic[size])
           <!--{if checkperm('managealbum')}-->
                <span class="pipe">|</span>IP: $pic[postip]
                <span class="pipe">|</span><a href="home.php?mod=spacecp&ac=album&picid=$pic[picid]&op=edithot&handlekey=picedithothk_{$pic[picid]}" id="a_hot_$pic[picid]" onclick="showWindow(this.id, this.href, 'get', 0);">{lang hot}</a>
            <!--{/if}-->
        </div>
   <!--/End Pic Author information -->    
   <!-- Begin Comment -->
        <div style="padding:5px; margin-top: 10px; background-color:#F0F2F7; position:relative;" class="cmt">
        <i class="x-nhot"></i>
            <div id="pic_comment" style="text-align:justify;">
            <!--{if $_G['uid']}-->
                <a href="home.php?mod=space&uid=$album[uid]&do=$do&picid=$picid#quickcommentform_{$picid}" onclick="if($('feedmessage_popup_comment')){$('feedmessage_popup_comment').focus();return false;}" class="y xi2 xw0">{lang publish_comment}</a>
                <!--{/if}-->
                <div class="pbn bbs">{lang comment} (<span id="pop_comment_replynum">$countcomment</span> {lang blog_replay})</div>
                <div id="feedcomment_$_GET[feedid]">
                    <!--{if $cid}-->
                    <div class="i">
                        {lang current_comment}
                    </div>
                    <!--{/if}-->
                    <div id="comment_ol_popup_comment" class="xld xlda">
                    <!--{eval $lastcid = 0;}-->
                    <!--{loop $list $value}-->
                        <!--{template home/space_comment_li}-->
                        <!--{eval $lastcid = $value['cid'];}-->
                    <!--{/loop}-->
                    </div>
                    <!--{if $_G['uid']}-->
                    <div id="form_comment_pic{$picid}" style="padding-right:10px; background-color:#F0F2F7">
                        <table cellpadding="0" width="100%">
                            <tr>
                                <td valign="top" width="50px">
                                    <div class="avt" style="padding:5px">
                                        <a href="home.php?mod=space&uid=$_G['uid']" class="avt_l" c="1">
                                            <!--{avatar($_G['uid'],small)}-->
                                        </a>
                                    </div>
                                </td>
                                <td width="*">
                                    <form id="quickcommentform_{$picid}" name="quickcommentform_{$picid}" action="home.php?mod=spacecp&ac=comment&handlekey=popup_comment" method="post" autocomplete="off" onsubmit="ajaxpost('quickcommentform_{$picid}', 'return_popup_comment');doane(event);" >
                                        <p>
                                            <span id="comment_face"  title="{lang insert_emoticons}"  onclick="showFace(this.id, 'feedmessage_popup_comment');return false;" class="cur1"><img src="{IMGDIR}/facelist.gif" alt="facelist" class="vm" /></span>
                                            <!--{hook/space_album_pic_face_extra}-->
                                            <!--{if $_G['setting']['magicstatus'] && !empty($_G['setting']['magics']['doodle'])}-->
                                            <a id="a_magic_doodle" href="home.php?mod=magic&mid=doodle&showid=comment_doodle&target=feedmessage_popup_comment" onclick="showWindow(this.id, this.href, 'get', 0)"><img src="{STATICURL}image/magic/doodle.small.gif" alt="doodle" class="vm" title="$_G['setting']['magics']['doodle']" /></a>
                                            <!--{/if}-->
                                        </p>
                                        <textarea id="feedmessage_popup_comment" onkeydown="ctrlEnter(event, 'commentsubmit_btn'); resizeTx(this);" name="message"  rows="1" class="pts" onblur="onckeydown=true; resizeTx(this); txtTxCommentChk(this.id, 2)" onclick="txtTxCommentChk(this.id, 1)"  onfocus="onckeydown=false; resizeTx(this); txtTxCommentChk(this.id, 1);"style="color:#CCC;">Viết bình luận...</textarea>
                                    <!--{if checkperm('seccode') && ($secqaacheck || $seccodecheck)}-->
                                        <!--{block sectpl}--><sec> <span id="sec<hash>" onclick="showMenu(this.id);"><sec></span><div id="sec<hash>_menu" class="p_pop p_opt" style="display:none"><sec></div><!--{/block}-->
                                        <div class="mtm mbm sec"><!--{subtemplate common/seccheck}--></div>
                                    <!--{/if}-->
                                    <p class="pns">
                                        <input type="hidden" name="refer" value="$theurl" />
                                        <input type="hidden" name="id" value="$picid" />
                                        <input type="hidden" name="idtype" value="picid" />
                                        <input type="hidden" name="commentsubmit" value="true" />
                                        <input type="hidden" name="quickcomment" value="true" />
                                        <button type="submit" name="commentsubmit_btn" value="true" style="display:none;" id="commentsubmit_btn" class="pn"{if !$_G[uid]} onclick="showWindow(this.id, this.form.action);return false;"{/if}><strong>{lang comment}</strong></button>
                                        <span id="__quickcommentform_{$picid}"></span>
                                        <span id="return_popup_comment"></span>
                                        <input type="hidden" name="formhash" value="{FORMHASH}" />
                                    </p>
                                    </form>
                                </td>
                            </tr>
                        </table>
                    </div>
                    <!--{/if}-->
                </div>
            </div>
        </div>
        <!--{if $multi_comment}--><div class="pgs cl mbm">$multi_comment</div><!--{/if}-->
    	<div style="clear:both"></div>
        <!-- /End Comment -->
    </div>
    <div id="pic_album_information_$pic[pic]" style="float:right; width: 270px; margin:10px 0; text-align:left">
        <h2 style="padding:5px;">{lang album}: <a href="home.php?mod=space&username=$space[username]&do=album&id=$album[albumid]">$album[albumname]</a></h2>
        <!--{if $album[picnum]}-->{lang current_pic}<!--{/if}-->&nbsp;
                <!--{if $album['friend']}-->
                <span class="xg1"> &nbsp; {$friendsname[$value[friend]]}</span>
                <!--{/if}-->
    </div>
    <div style="clear:both"></div>
</div>
<script type="text/javascript" language="javascript" reload="1">
	var pop_picid_lastcid 	= parseInt({$lastcid});
	var pop_pic_id			= parseInt({$picid});
	resizeImg('comment_ol_popup_comment','350');
</script>
<!--{template common/footer_ajax}-->